#include<bits/stdc++.h>
using namespace std;
const int inf=100010;
int n,r[inf],ri,cntr,cnt[inf],ctr[inf],ans;
int main()
{
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    cin>>n;
    ans=n;
    for(int i=1;i<=n;i++)
    {
        cin>>ri;
        if(cnt[ri]==0)r[++cntr]=ri;
        cnt[ri]++;
        ctr[ri]++;
    }
    sort(r+1,r+1+cntr);
    for(int i=1;i<=cntr;i++)
    {
        int j=i+1;
        while(cnt[r[i]]>0&&j<=cntr)
        {
            int tmp=min(cnt[r[i]],ctr[r[j]]);
            ans-=tmp;
            cnt[r[i]]-=tmp;
            ctr[r[j]]-=tmp;
            j++;
        }
    }
    cout<<ans;
    return 0;
}
